import 'package:device_info_plus/device_info_plus.dart';
import 'package:flutter/services.dart';

class DeviceUtil {
  /// 获取androidId复制到剪切板
  static copyAndroidId() async {
    final deviceInfoPlugin = DeviceInfoPlugin();
    final deviceInfo = await deviceInfoPlugin.deviceInfo;
    final map = deviceInfo.toMap();
    Clipboard.setData(ClipboardData(text: '${map['androidId']}'));
  }
}
